package com.mingda.weathermagiccenter.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import lombok.Data;

/**
 * 
 * @TableName ws_station
 */
@TableName(value ="ws_station")
@Data
public class WsStation implements Serializable {
    /**
     * 站点ID
     */
    @TableId(value = "stationkey")
    private String stationkey;

    /**
     * 
     */
    @TableField(value = "lat")
    private Float lat;

    /**
     * 
     */
    @TableField(value = "lon")
    private Float lon;

    /**
     * 
     */
    @TableField(value = "alt")
    private Float alt;

    /**
     * 站点名称
     */
    @TableField(value = "stationname")
    private String stationname;

    /**
     * 所属机构
     */
    @TableField(value = "orgid")
    private String orgid;

    /**
     * 机构名称
     */
    @TableField(value = "orgname")
    private String orgname;

    /**
     * 
     */
    @TableField(value = "remark")
    private String remark;

    /**
     * 站点类型 
1. 国家站 
2. 区域站
3. 火险监测站(海康)
     */
    @TableField(value = "stationtype")
    private String stationtype;

    /**
     * 设备型号
     */
    @TableField(value = "devicetype")
    private String devicetype;


    @TableField(value = "alarmflag")
    private String alarmflag;


    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        WsStation other = (WsStation) that;
        return (this.getStationkey() == null ? other.getStationkey() == null : this.getStationkey().equals(other.getStationkey()))
            && (this.getLat() == null ? other.getLat() == null : this.getLat().equals(other.getLat()))
            && (this.getLon() == null ? other.getLon() == null : this.getLon().equals(other.getLon()))
            && (this.getAlt() == null ? other.getAlt() == null : this.getAlt().equals(other.getAlt()))
            && (this.getStationname() == null ? other.getStationname() == null : this.getStationname().equals(other.getStationname()))
            && (this.getOrgid() == null ? other.getOrgid() == null : this.getOrgid().equals(other.getOrgid()))
            && (this.getOrgname() == null ? other.getOrgname() == null : this.getOrgname().equals(other.getOrgname()))
            && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
            && (this.getStationtype() == null ? other.getStationtype() == null : this.getStationtype().equals(other.getStationtype()))
            && (this.getDevicetype() == null ? other.getDevicetype() == null : this.getDevicetype().equals(other.getDevicetype()))
            && (this.getAlarmflag() == null ? other.getAlarmflag() == null : this.getAlarmflag().equals(other.getAlarmflag()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getStationkey() == null) ? 0 : getStationkey().hashCode());
        result = prime * result + ((getLat() == null) ? 0 : getLat().hashCode());
        result = prime * result + ((getLon() == null) ? 0 : getLon().hashCode());
        result = prime * result + ((getAlt() == null) ? 0 : getAlt().hashCode());
        result = prime * result + ((getStationname() == null) ? 0 : getStationname().hashCode());
        result = prime * result + ((getOrgid() == null) ? 0 : getOrgid().hashCode());
        result = prime * result + ((getOrgname() == null) ? 0 : getOrgname().hashCode());
        result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
        result = prime * result + ((getStationtype() == null) ? 0 : getStationtype().hashCode());
        result = prime * result + ((getDevicetype() == null) ? 0 : getDevicetype().hashCode());
        result = prime * result + ((getAlarmflag() == null) ? 0 : getAlarmflag().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", stationkey=").append(stationkey);
        sb.append(", lat=").append(lat);
        sb.append(", lon=").append(lon);
        sb.append(", alt=").append(alt);
        sb.append(", stationname=").append(stationname);
        sb.append(", orgid=").append(orgid);
        sb.append(", orgname=").append(orgname);
        sb.append(", remark=").append(remark);
        sb.append(", stationtype=").append(stationtype);
        sb.append(", devicetype=").append(devicetype);
        sb.append(", alarmflag=").append(alarmflag);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}